﻿// Decompiled with JetBrains decompiler
// Type: UnityEngine.ExposedPropertyResolver
// Assembly: UnityEngine.CoreModule, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
// MVID: E6AE6B5A-2752-4B07-9528-C8B77C62CE79
// Assembly location: C:\Users\windys\Unity\2021.3.39f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.CoreModule.dll
// XML documentation location: C:\Users\windys\Unity\2021.3.39f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.CoreModule.xml

using System;
using System.Runtime.CompilerServices;
using UnityEngine.Bindings;

#nullable disable
namespace UnityEngine
{
  /// <summary>
  ///   <para>Object that is used to resolve references to an ExposedReference field.</para>
  /// </summary>
  [NativeHeader("Runtime/Director/Core/ExposedPropertyTable.bindings.h")]
  [NativeHeader("Runtime/Utilities/PropertyName.h")]
  public struct ExposedPropertyResolver
  {
    internal IntPtr table;

    internal static Object ResolveReferenceInternal(
      IntPtr ptr,
      PropertyName name,
      out bool isValid)
    {
      return !(ptr == IntPtr.Zero) ? ExposedPropertyResolver.ResolveReferenceBindingsInternal(ptr, name, out isValid) : throw new ArgumentNullException("Argument \"ptr\" can't be null.");
    }

    [FreeFunction("ExposedPropertyTableBindings::ResolveReferenceInternal")]
    private static Object ResolveReferenceBindingsInternal(
      IntPtr ptr,
      PropertyName name,
      out bool isValid)
    {
      return ExposedPropertyResolver.ResolveReferenceBindingsInternal_Injected(ptr, ref name, out isValid);
    }

    [MethodImpl(MethodImplOptions.InternalCall)]
    private static extern Object ResolveReferenceBindingsInternal_Injected(
      IntPtr ptr,
      ref PropertyName name,
      out bool isValid);
  }
}
